<?php

namespace core;

class myFrame{
	public static $classMap = array();
	static public function run()
	{
		test('欢迎来到亢浩楠的框架！！！');
		//测试自动加载类
		$route = new \core\lib\route();
	}

	static public function load($class)
	{
		//自动加载类库
		$class=str_replace('\\', '/', $class);
		$file=ROOT_DIR.'/'.$class.'.php';
		if(isset($classMap['class']))
		{
			return true;
		}
		else
		{
			if(is_file($file))
			{
				include $file;
				self::$classMap['class'] = $class;
			}
			else{
				return false;
			}
		}
		
	}
}